package com.example.service.impl;

import com.example.pojo.user.RolePermission;
import com.example.dao.RolePermissionDao;
import com.example.service.RolePermissionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class RolePermissionServiceImpl implements RolePermissionService {
    @Autowired
    RolePermissionDao rolePermissionDao;

    @Override
    public int deleteByPrimaryKey(Integer id) {
        return rolePermissionDao.deleteByPrimaryKey(id);
    }

    @Override
    public int insert(RolePermission record) {
        return rolePermissionDao.insert(record);
    }

    @Override
    public int insertSelective(RolePermission record) {
        return insert(record);
    }

    @Override
    public List<RolePermission> listPermission() {
        return rolePermissionDao.listPermission();
    }

    @Override
    public RolePermission selectByPrimaryKey(Integer id) {
        return rolePermissionDao.selectByPrimaryKey(id);
    }

    @Override
    public int updateByPrimaryKeySelective(RolePermission record) {
        return rolePermissionDao.updateByPrimaryKeySelective(record);
    }

    @Override
    public List<String> listRole() {
        return rolePermissionDao.listRole();
    }

    @Override
    public int updateByPrimaryKey(RolePermission record) {
        return rolePermissionDao.updateByPrimaryKey(record);
    }
}
